(function (factory) {
    if (typeof module === "object" && typeof module.exports === "object") {
        var v = factory(require, exports);
        if (v !== undefined) module.exports = v;
    }
    else if (typeof define === "function" && define.amd) {
        define(["require", "exports", "maishu-ui-toolkit"], factory);
    }
})(function (require, exports) {
    "use strict";
    Object.defineProperty(exports, "__esModule", { value: true });
    const ui = require("maishu-ui-toolkit");
    let errorMessages = {
        "726": "没有权限访问"
    };
    function errorHandle(error, app, page) {
        error.message = errorMessages[error.name] || error.message;
        ui.alert({
            title: "错误",
            message: error.message
        });
    }
    exports.default = errorHandle;
});
